﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Master.Master" AutoEventWireup="true" CodeBehind="Photos.aspx.cs" Inherits="KFSNetwork.Photos" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajax" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
        <style type="text/css">
            .Image
            {
                  width:600px;
                  margin:0px auto;
                  text-align:center;
                  padding:20px;
                  border:1px gray;
                  background-color:Silver;
              }
        </style>
   
        <script type="text/javascript">
            function pageLoad() {
                var slide = $find('SSBehaviorID');
                slide.add_slideChanging(animateSlides);
                var ae = $find("ae");
                var be = ae.get_OnLoadBehavior();
                var an = be.get_animation();
                fadein = an.get_animations()[1];
                fadeout = an.get_animations()[0];

                fadein.set_duration(1.0);
                fadeout.set_duration(1.0);

            }

            function animateSlides() {
                fadein.play();
                window.setTimeout("fadeout.play()", 2000);

            } 
   
        </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<%--    <br />
   
    <h3><asp:Label ID="lblLinks" runat="server" Text="Photos" CssClass="pageHeaders" /></h3>--%>

        <div style="text-align: center">
        
        
        <script runat="Server" type="text/C#">
        [System.Web.Services.WebMethod]
        [System.Web.Script.Services.ScriptMethod]
        public static AjaxControlToolkit.Slide[] GetSlides()
        {
            AjaxControlToolkit.Slide[] slides = new AjaxControlToolkit.Slide[5];

            slides[0] = new AjaxControlToolkit.Slide("Images/slideshow/youngbillweb.png", "", "Bill with Senator McConnell, ELECTION NIGHT 1990, Bill served campaign as state chairman \"democrats for McConnell\"");
            slides[1] = new AjaxControlToolkit.Slide("Images/slideshow/MitchwBillweb.png", "", "Bill with Senator McConnell, Back home in KY 2011");
            slides[2] = new AjaxControlToolkit.Slide("Images/slideshow/Clintonweb.png", "", "Bill with President Bill Clinton, Town Hall meeting KY 1994");
            slides[3] = new AjaxControlToolkit.Slide("Images/slideshow/carterbig.jpg", "", "Bill with President Jimmy Carter, Campaigning KY 1980");
            return(slides);
        }
        </script>

        &nbsp; &nbsp;<br />
        <br />
            
        <asp:Image ID="Image1" runat="server" Height="600px" Width="725px" /><br />
        <br />
            
        <asp:Label ID="lblImageDescription" runat="server" /><br />
        <br />
    
        <asp:ImageButton ID="Btn_Previous" runat="server" ImageUrl="~/Images/previous.png" />
        <asp:ImageButton ID="Btn_Next" runat="server" Width="64px" ImageUrl="~/Images/next.png" /><br />
        <asp:ImageButton ID="Btn_Play" runat="server" Text="Play" Visible="true" ImageUrl="~/Images/play.png" Width="0px" Height="0px" /><br />
        <br />
    
        <ajax:SlideShowExtender ID="SlideShowExtender1"
            AutoPlay="false" ImageDescriptionLabelID="lblImageDescription"
            Loop="true" NextButtonID="Btn_Next" PlayButtonID="Btn_Play" 
            PlayButtonText="Play" PreviousButtonID="Btn_Previous" 
                SlideShowServiceMethod="GetSlides" StopButtonText="Stop"
                TargetControlID="Image1" runat="server">
        </ajax:SlideShowExtender>       
    </div>
       
</asp:Content>
